import 'package:flutter/material.dart';

import 'package:junyeyishu/utils/utils.dart';
import 'package:junyeyishu/widgets/QGWidget.dart';

class QGMineItem extends StatelessWidget {
  final String? icon;
  final String? name;
  final double? opacity;
  final VoidCallback? onPressed;
  const QGMineItem(
      {super.key, this.icon, this.name, this.opacity, this.onPressed});

  @override
  Widget build(BuildContext context) {
    return GestureDetector(
      onTap: onPressed,
      child: Container(
        color: Colors.transparent,
        alignment: Alignment.center,
        width: 80.rpx,
        child: Column(
          children: [
            QGImage(asset: icon, width: 24.rpx),
            SizedBox(height: 10.rpx),
            Text(
              "$name",
              style: TextStyle(
                  fontSize: 12.rpx,
                  fontWeight: FontWeight.normal,
                  color: Color(0xFF111111)),
            ),
          ],
        ),
      ),
    );
  }
}
